(function($){

window.addEvent('domready', function(){

	//Shortcut of namespace
	var moo = MPG;

	var container = $('gallery');
	var gallery = new moo.Gallery(container, {
		actions: {
			defaultAction: '/content/default.html',
			landscapeAction: '/content/landscape.html',
			portraitAction: '/content/portrait.html'
		}
	});

	//The controller who uses it for the gallery is specified.
	gallery.addControl(new moo.NavigaterControl($('navigater')))
		.addControl(new moo.SwipeControl())
		.addControl(new moo.OrientationControl())
		.run();

});

}(document.id));